<html>
<head>
  <style type="text/css" media="screen">
    body {
        overflow: hidden;
    }

    iframe {
        position: absolute;
        top: 0px;
        left: 0px;
        height: 300px;
        width: 300px;
    }

    #overlap {
        left: 250px;
    }

    pre {
        position: absolute;
        bottom: 2000px;
        left: 0px;
    }
  </style>
  <script>
    if (window.testRunner) {
        testRunner.dumpAsText();
    }

    function doTest()
    {
        if (window.testRunner) {
            document.getElementById('layers').innerHTML = internals.layerTreeAsText(document);
        }
    }

    window.addEventListener('load', doTest, false);
  </script>
</head>
<body>

    <iframe src="resources/composited-subframe.html"></iframe>
    <!-- this iframe should become composited because it overlaps the other iframe -->
    <iframe id="overlap" src="resources/subframe.html"></iframe>

    <pre id="layers">Layer tree appears here in DRT.</pre>
</body>
</html>
